[POWERPC][XEN] Ignore device tree nodes missing "device_type".
authorHollis Blanchard <hollisb@us.ibm.com>
Tue, 21 Nov 2006 21:25:02 +0000 (15:25 -0600)
committerHollis Blanchard <hollisb@us.ibm.com>
Tue, 21 Nov 2006 21:25:02 +0000 (15:25 -0600)
The latest release of SLOF is missing mandatory "device_type" properties for
the ISA and system-controller busses. Work around it by just printing a warning
and continuing.
CC: Segher Boessenkool <segher@kernel.crashing.org>
Signed-off-by: Amos Waterland <apw@us.ibm.com>
Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com>
--HG--
extra : transplant_source : y%01Ue%D3H%7B%1CL%0DLc%02P%D6%85%AC%E8%1F%07

xen/arch/powerpc/boot_of.c

index c81ca2b9ebd9eb7f8d034ef0e56be96c512e14c6..9bc897cbc8eb4018113f6f60e0758e4cc70acd83 100644 (file)
@@ -818,8 +818,10 @@ static int __init boot_of_serial(void *oft)
             of_panic("package-to-path failed\n");
 
         rc = of_getprop(p, "device_type", type, sizeof (type));
-        if (rc == OF_FAILURE)
-            of_panic("fetching device type failed\n");
+        if (rc == OF_FAILURE) {
+            of_printf("%s: fetching type of `%s' failed\n", __func__, buf);
+            continue;
+        }
 
         if (strcmp(type, "serial") != 0)
             continue;